package com.augurit.common.base.form;

import java.util.List;

import com.augurit.common.sysfile.service.ISysFileService;
import com.augurit.common.sysfile.web.form.SysFileForm;

/**
 * 业务Form类如果带有附件管理功能则需要继承该类
 */
public class AttachmentMgmtForm extends BaseForm {

	/**
	 * 加载附件列表
	 * @param form
	 * @param entity
	 * @param entityId
	 * @param sysFileService
	 */
	public void loadAttachmentList(String entity, String entityId, ISysFileService sysFileService){
		List<SysFileForm> list = sysFileService.getByEntityAndEntityId(entity, Long.valueOf(entityId));
		this.setAttachmentList(list);
	}
	
	//属性
	private List<SysFileForm> attachmentList;	//附件列表

	public List<SysFileForm> getAttachmentList() {
		return attachmentList;
	}

	public void setAttachmentList(List<SysFileForm> attachmentList) {
		this.attachmentList = attachmentList;
	}
}
